<?php
/*
 * Created on Jan 27, 2012
 *
 * To change the template for this generated file go to
 * Window - Preferences - PHPeclipse - PHP - Code Templates
 */

class ConvertUtils
{
	public static function getAttributeIdForPromoType($promoTypeName)
	{
		$attributeId 	= 0;
		
		switch (strtolower($promoTypeName)) {
		    case "ongoing promotion":
		        $attributeId = 31; 
		        break;
		    case "sale":
		       $attributeId = 32; 
		        break;
		    case "coupon":
		        $attributeId = 33; 
		        break;
		    case "unspecified":
		        $attributeId = 34; 
		        break;
		    case "price cut":
		        $attributeId = 35; 
		        break;
		    case "product promotion":
		        $attributeId = 36; 
		        break;
		    case "free shipping":
		        $attributeId = 2; 
		        break;
		    case "percent off":
		        $attributeId = 1; 
		        break;
		    case "free gift":
		        $attributeId = 37; 
		        break;
		    case "sweepstakes":
		        $attributeId = 38; 
		        break;
		    case "free gift wrap":
		        $attributeId = 39; 
		        break;
		    case "buy x get y":
		        $attributeId = 40; 
		        break;
		    case "percentage off":
		        $attributeId = 1; 
		        break;
		    case 'dollar off':
		        $attributeId = 3; 
		        break;
		    case "gift with purchase":
		        $attributeId = 43; 
		        break;
		    case "combination savings":
		        $attributeId = 44; 
		        break;
		    case "general promotion":
		        $attributeId = 45; 
		        break;
		    case "clearance":
		        $attributeId = 46; 
		        break;
		    case "deal of the day/week":
		        $attributeId = 47; 
		        break;
		    case "buy one / get one":
		        $attributeId = 40; 
		        break;
		    case "free trial/use":
		        $attributeId = 48; 
		        break;
		    case "black friday":
		        $attributeId = 49; 
		        break;
		    case "cyber monday":
		        $attributeId = 50; 
		        break;
		    case "free trial / usage":
		        $attributeId = 63; 
		        break;

	
		}
		
		return $attributeId;
	}
}

?>
